package cn.rkylin.oms.sysOrder.service;

import cn.rkylin.oms.sysOrder.domain.SysOrderGoods;
import cn.rkylin.oms.sysOrder.vo.SysOrderVO;

import java.util.List;
import java.util.Map;

/**
 * 系统订单服务层接口
 *
 * @author wangxing
 * @version 1.0
 * @created 2017.09.14
 */
public interface ISysOrderService {


    /**
     * 生成系统订单(1、订单进系统；2、订单合并；3、计算促销上赠品；4、订单更新)
     *
     * @param shopId 店铺id
     * @return
     * @throws Exception
     */
    public int generateSysOrder(String shopId, String buyerNick, String tradeCode) throws Exception;

    /**
     * 自动审核分派
     *
     * @param shopId 店铺id
     */
    public int verifyAndAssignOrder(String shopId) throws Exception;

    /**
     * getSysOrderList:获取系统订单列表. <br/>
     *
     * @param sysOrderMap
     * @return
     * @throws Exception
     * @author zhanghao
     */
    public List<SysOrderVO> getSysOrderList(Map<String, String> sysOrderMap) throws Exception;

    /**
     * updateLockOrder:锁定订单. <br/>
     *
     * @param sysOrderVO
     * @author zhanghao
     */
    public int updateLockOrder(SysOrderVO sysOrderVO) throws Exception;

    /**
     * 更新系统订单商品明细
     *
     * @param record
     * @return
     * @throws Exception
     */
    public int updateByPrimaryKeySelectiveSysOrderGoods(SysOrderGoods record) throws Exception;

}